// 函数定义
function add(x: number, y: number, z?: number): number {
  return x + y;
}
// 函数表达式定义
const getData: (param: Object) => [] = (param) => []
// 箭头函数的类型定义
const fn = (e: 'tabClick', param: object): number => {
  return 2;
}